<template>
  <view class="page-order-detail">
    <view class="p-a-15 flex-between">
      <view class="title ftb-17">
        状态名
      </view>
      <van-button type="info" size="small">评价</van-button>
    </view>
    <van-cell-group>
      <van-cell title="运单编号" :value="'xxx'" size="large" />
      <van-cell title="运单金额" :value="'xxx'" size="large" />
      <van-cell title="运输方式" :value="'xxx'" size="large" />
      <van-cell title="计划发货时间" :value="'xxx'" size="large" />
      <van-cell title="发货地" :value="'xxx'" size="large" />
      <van-cell title="收货地" :value="'xxx'" size="large" />
      <van-cell title="装运说明" :value="'xxx'" size="large" />
      <van-cell title="备注" :value="'xxx'" size="large" />
    </van-cell-group>
    <view class="p-a-15">
      <view class="title title-v p-y-15 ftb-17">关联订单（2个）</view>
      <view class="fly-panel">
        <view class="hd"><text class="title">订单编号：00000</text></view>
        <view class="bd">
          <view class="bd-ul">
            <fly-info label="货主：" :value="'pageParams.lvtoReferralBillId'" />
            <fly-info label="货物：" :value="'pageParams.updateTime'" />
            <fly-info label="计划发货时间：" :value="'pageParams.payAmt'" /> 
            <fly-info label="发货地：" :value="'pageParams.payAmt'" /> 
            <fly-info label="收货地：" :value="'pageParams.payAmt'" /> 
          </view>         
        </view>
        <view class="ft flex-between">
          <view class="c-grey">2024-01-01</view>
          <view class="btn">
            <van-button type="info" size="small" @tap="$utils.gotoPage('/packageB/bill/index', {status: 1})">{{getBtnTxt(1)}}</van-button>
          </view>
        </view>
      </view>
    </view>
    <view class="p-a-10"></view>
  </view>
</template>

<script>
import flyInfo from '@/components/flyInfo';
import flyUpload from '@/components/flyUpload';
export default {
  data(){
    return{
      pageParams: {},
      info:{

      },
      icon:{
        excel: this.$icon.excel,
        profile: this.$icon.profile,
        visittime: this.$icon.visittime,
      },
      list: [],
    }
  },
  components:{
    flyInfo,
    flyUpload
  },
  onLoad(e){
    this.pageParams = e;
    // this.getList();
  },
  methods:{
    getList(){
      this.$http('get', '/lvto/lvtoReferralFollow/xcx/'+this.pageParams.lvtoReferralBillId,{}, (data,msg) => {
        if(data.length > 0){
          this.list = data.map(item => {
            item.imgList = [];
            return item;
          });
        }
      });
    },
    getBtnTxt(status){
      let txt = '详情';
      switch(status){
        case 0 : 
          txt = '装车';
          break;
        case 1 : 
          txt = '卸车';
          break;
        case 2 : 
          txt = '验收';
          break;
        default:
          txt = '详情';
          break;
      }
      return txt;
    }
  }
}
</script>